module.exports = {
  checkLogin: function checkLogin(req, res, next) {
  	console.log('checkLogin',req.body);
    if (!req.session.user) {
      // return res.redirect('/signin/signin.html');
      // return res.render('../public/signin/signin.html');
      return res.send('home');
    };
    next();
  },

  checkNotLogin: function checkNotLogin(req, res, next) {
    if (req.session.user) {
      //return res.redirect('back'); //返回之前的页面
    };
    next();
  }
};
